|
|
|
|
|
|
|
Product Name. For the sake of simplicity, ignore the command-line and conditional compilation arguments, as well as the Compile and Component tabs; use the default values. Click the OK button. |
|
|
|
|
|
|
|
|
Figure 6.3.
The Make index tab of the Project
Properties dialog box. |
|
|
|
|
|
|
|
|
At this time, you should create two classes for the component project. Using what you've learned about adding classes to a Visual Basic project, add a class module for the class Deposit and the class BasicPersonalCheckingAccount, using the class specifications indicated in Listing 6.1. For the Deposit class, make the property Amount the default property if you use Class Builder (see Figure 6.4). When adding the depositFunds method, make sure it is the default method (see Figure 6.5). Having these defaults means that you don't have to explicitly type these class members in codethey are accessed by default. |
|
|
|
|
|
|
|
|
Figure 6.4.
The default property for the BasicPersonalCheckingAccount class. |
|
|
|
|
|
|
|
|
You now have one class in your component project. Figure 6.6 gives you an idea of what your project should now look like. Add the code from Listing 5.1 to your class modules. |
|
|
|
|
|